#include<stdio.h>
main()
{
    int year,mon;
    printf("Input a year:");
    scanf("%d",&year);
    if(year%4==0&&year%100!=0||year%400==0)
    {
        printf("this year is a leap year.\n");
    }
    else
    {
        printf("this year is not a leap year,man!\n");
    }
    if(year>=0)
    {
      printf("Input a month:");
      scanf("%d",&mon);
      switch(mon)
        {
          case 1:
            printf("the month contains 31 days");
            break;
          case 2:
            if(year%4==0&&year%100!=0||year%400==0)
            {
                printf("the month contains 29 days");
            }
            else
                printf("the month contains 28 days");
            break;
          case 3:
            printf("the month contains 31 days");
            break;
          case 4:
            printf("the month contains 30 days");
            break;
          case 5:
            printf("the month contains 31 days");
            break;
          case 6:
            printf("the month contains 30 days");
            break;
          case 7:
            printf("the month contains 31 days");
            break;
          case 8:
            printf("the month contains 31 days");
            break;
          case 9:
            printf("the month contains 30 days");
            break;
          case 10:
            printf("the month contains 31 days");
            break;
          case 11:
            printf("the month contains 30 days");
            break;
          case 12:
            printf("the month contains 31 days");
            break;
          default:
            printf("the month you input doesn't even exist!");
        }
    }
    else
        printf("input incorrectly!");
}
